using System;

namespace Be.Timvw.Framework.ComponentModel
{
    public class ComparableIdentification : IComparable
    {
        private int id;

        public ComparableIdentification(int id)
        {
            this.id = id;
        }

        public int Id
        {
            get { return this.id; }
            set { this.id = value; }
        }

        #region IComparable Members

        public int CompareTo(object obj)
        {
            ComparableIdentification other = obj as ComparableIdentification;
            if(other == null)
            {
                return 1;
            }

            return this.id.CompareTo(other.id);
        }

        #endregion
    }
}